package com.huawei.hms.common;

import android.os.Parcel;
import android.os.Parcelable.Creator;

public final class a implements Creator<Feature> {
    public /* synthetic */ Object createFromParcel(Parcel parcel) {
        return a(parcel);
    }

    public /* synthetic */ Object[] newArray(int i) {
        return a(i);
    }

    public final Feature[] a(int i) {
        return new Feature[i];
    }

    public final Feature a(Parcel parcel) {
        int b = com.huawei.hms.common.internal.safeparcel.a.b(parcel);
        String str = null;
        int i = 0;
        long j = -1;
        while (parcel.dataPosition() < b) {
            int a = com.huawei.hms.common.internal.safeparcel.a.a(parcel);
            switch (com.huawei.hms.common.internal.safeparcel.a.a(a)) {
                case 1:
                    str = com.huawei.hms.common.internal.safeparcel.a.e(parcel, a);
                    break;
                case 2:
                    i = com.huawei.hms.common.internal.safeparcel.a.c(parcel, a);
                    break;
                case 3:
                    j = com.huawei.hms.common.internal.safeparcel.a.d(parcel, a);
                    break;
                default:
                    com.huawei.hms.common.internal.safeparcel.a.b(parcel, a);
                    break;
            }
        }
        com.huawei.hms.common.internal.safeparcel.a.h(parcel, b);
        return new Feature(str, i, j);
    }
}
